---
import { ClientRouter } from "astro:transitions"

interface Props {
  title: string
}

const { title } = Astro.props
const description =
  "Proyectos prácticos para aprender JavaScript con código fuente y vídeo. Totalmente gratis."
---

<!doctype html>
<html lang="es">
  <head>
    <title>{title}</title>
    <meta charset="UTF-8" />
    <meta name="description" content={description} />
    <meta name="author" content="Miguel Ángel Durán" />
    <meta
      name="keywords"
      content="javascript, js, programación, desarrollo web"
    />
    <meta name="theme-color" content="#f7df1e" />
    <meta name="twitter:card" content="summary_large_image" />
    <meta name="twitter:creator" content="@midudev" />
    <meta name="twitter:title" content={title} />
    <meta name="twitter:description" content={description} />
    <meta name="twitter:image" content="https://javascript100.dev/og.jpg" />
    <meta property="og:title" content={title} />
    <meta property="og:description" content={description} />
    <meta property="og:image" content="https://javascript100.dev/og.jpg" />
    <link rel="canonical" href="https://javascript100.dev" />
    <meta name="viewport" content="width=device-width" />
    <link rel="icon" type="image/svg+xml" href="/favicon.svg" />
    <ClientRouter />
  </head>
  <body>
    <slot />
    <style is:global>
      @import "tailwindcss";

      html {
        font-family: system-ui, sans-serif;
      }

      code {
        font-family:
          Menlo,
          Monaco,
          Lucida Console,
          Liberation Mono,
          DejaVu Sans Mono,
          Bitstream Vera Sans Mono,
          Courier New,
          monospace;
      }
    </style>
  </body>
</html>
